﻿/* Original Author:  Dominick O'Dierno
 * Date: 2007   odiernod@gmail.com     --Originally intended for use with DOMercury:  http://www.odierno.com/domercury
 * Description: Handles Saving and loading configuration
 *
 * --CHANGELOG--
 * 2008-05-18 - Tao Klerks:
 *  - created this separate instance class, in the interfaces project so that it can be accessed from settings 
 *     management 
 * 2008-05-21 - Tao Klerks:
 *  - moved class into its own project, because it simply does not belong in PluginReferences
 *  - Added storage of interface options
 * 2008-05-22 - Tao Klerks:
 *  - Corrected storage of interface options to support multiple Interfaces
 * 
 * */

using System;
using System.Collections.Generic;
using System.Text;
using System.Collections;
using System.Xml;
using DOMercury.Utilities;

namespace DOMercury.ConfigSupport
{
    [Serializable]
    public class ConfigurationInstance
    {
        public bool AltKey;
        public bool CheckUpdates;
        public bool CtrlKey;
        public string CurrentInterface;
        public string KeyCode;
        public DateTime LastChecked;
        public int MaxResults;
        public bool ShiftKey;
        public bool ShowFailAlerts;
        public bool SmartSearch;
        public bool WindowsKey;
        public bool LocalStorage;
        public SerializableDictionary<string, XmlDocument> PluginSettings;
        public SerializableDictionary<string, XmlDocument> InterfaceSettings;

        public ConfigurationInstance()
        {
            AltKey = false;
            CheckUpdates = true;
            CtrlKey = false;
            CurrentInterface = "Skins/Default/Default.skin";
            KeyCode = "Z";
            LastChecked = DateTime.Now.Subtract(TimeSpan.FromDays(1.0));
            MaxResults = 20;
            ShiftKey = false;
            ShowFailAlerts = true;
            SmartSearch = true;
            WindowsKey = true;
            LocalStorage = true;
            PluginSettings = new SerializableDictionary<string, XmlDocument>();
            InterfaceSettings = new SerializableDictionary<string, XmlDocument>();
        }

    }
}
